<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Sửa đổi bài viết</title>
</head>

<body>
<?PHP
	
	require ('models/m_baiviet.php'); 
	$post=getbyid_bv($_GET['id']);
	$nbv=nbv();
	if (isset($_POST['update']) )
			{ 
				update_bv($_POST);
				$post=getbyid_bv($_GET['id']); 
		        header('Location: suabaiviet.php?id='.$_GET['id']);

			
			}
	if (isset($_POST['update1']) )
			{ 
				update_bv1($_POST);
				$post=getbyid_bv($_GET['id']); 
		        header('Location: suabaiviet.php?id='.$_GET['id']);

			
			}		

	require ('v_baiviet_sua.php'); 
	
?>
</body>
</html>